package com.test.common.response;

public enum ResultCode {

    SUCCESS(200, "成功"),
    PARAM_IS_INVALID(100000, "参数错误！"),

    USER_NOTLOGGED_IN(100001, "用户未登录，请登陆后操作！"),
    USER_LOGIN_ERROR(100002, "用户名或密码错误！"),
    USER_ACCOUNT_LOCKED(100003, "账号已被锁定,请联系管理员！"),
    USER_TOKEN_ERROR(100004, "登录已失效，请重新登录！"),

    SYSTEM_ERROR(999999, "系统异常，请稍后重试！");

    private final Integer code;
    private final String message;

    ResultCode(Integer code, String message) {
        this.code = code;
        this.message = message;
    }

    public Integer code() {
        return this.code;
    }

    public String message() {
        return this.message;
    }
}
